package com.qumitech.visualnovel.datasource.console;

import com.qumitech.visualnovel.model.dao.console.PropertyChange;
import org.apache.ibatis.annotations.Param;

import java.util.HashMap;
import java.util.List;

public interface PropertyChangeMapper {
    int deleteByPrimaryKey(Long addedId);

    int insert(PropertyChange record);

    int insertSelective(PropertyChange record);

    PropertyChange selectByPrimaryKey(Long addedId);

    int updateByPrimaryKeySelective(PropertyChange record);

    int updateByPrimaryKey(PropertyChange record);

    int getCount(@Param("tableName") String tableName,
                 @Param("accountId") Integer accountId,
                 @Param("propertyId") String propertyId,
                 @Param("changeId")  String changeId,
                 @Param("fuzzyModel") boolean fuzzyModel);

    List<PropertyChange> getList(@Param("tableName") String tableName,
                                 @Param("accountId") Integer accountId,
                                 @Param("propertyId") String propertyId,
                                 @Param("changeId")  String changeId,
                                 @Param("offset") Integer offset,
                                 @Param("limit") Integer limit,
                                 @Param("orderType") String orderType,
                                 @Param("orderBy") String orderBy,
                                 @Param("fuzzyModel") boolean fuzzyModel);

    List<HashMap<String,Object>> getReasonOptions();
}